{template Public:Page:header}

<div class="container">
  <div class="row">
  
    {template Member:Index:sidebar}
    
    <div class="col-lg-10 well-col-pl-30">
      <div class="row">
            <div class="well">

                <h3>免费开店</h3>
               	<div class="row">
                      <div class="col-lg-12 col-sm-12 col-xs-12">
                        <div class="wizard wizard-wired">
                          <ul class="steps">
                            <li class="complete" data-target="#wiredstep1"><span class="step">1</span><span class="title">填写店铺信息</span> <span class="chevron"></span></li>
                            <li class="complete" data-target="#wiredstep2"><span class="step">2</span><span class="title">实名认证</span> <span class="chevron"></span></li>
                            <li {if $certificate['status']==5}class="complete"{else}class="active"{/if} data-target="#wiredstep3"><span class="step">3</span><span class="title">审核</span> <span class="chevron"></span></li>
                          </ul>
                        </div>
                      </div>
                </div>

        
            <br />
        <div class="row"> 
        <div class="col-lg-11 col-lg-offset-1">

        	  <div class="row">
              <h4>认证信息</h4>
              
              <p>店铺名称：{echo $member['shopname']}</p>
              
              <p>店铺类型：{if $certificate['usertype']==1}个人{else}企业{/if}</p>
              
              <p>认证名称：{echo $certificate['realname']}</p>
              
              <p>认证证件：</p>
              <p><a href="/{echo $certificate['filepath']}" target="_blank"><img src="/{echo $certificate['thumbcut']}" /></a></p>
              
              <hr />
              
              <h4>认证状态：{if $certificate['status']==1}申请中{elseif $certificate['status']==2}认证失败{elseif $certificate['status']==5}认证成功{else}重新申请{/if}</h4>
              
              {if $certificate['status']==2}
                  <div class="alert alert-danger fade in">
                        <button data-dismiss="alert" class="close">
                            ×
                        </button>
                        <i class="fa-fw fa fa-times"></i>
                        <strong>失败!</strong> {echo $certificate['content']}
                  </div>
              
              {/if}
              
              {if $certificate['status']==5}
              <p><a href="/shop/{echo $certificate['uid']}" class="btn" target="_blank">查看店铺</a></p>
              {/if}
  
 			   </div>
      	  
             <br>
             </div>
             
			 {if $certificate['status']==2}
             <div class="row">
               <div class="col-lg-11 col-lg-offset-1">
               	<button class="btn btn-success" type="submit" id="NewCertificate">重新申请</button>
               </div>
            </div>
            {/if}

   
				</div>
               
            </div>
    </div>
  </div>
</div>
</div>
<script>							
$(function(){
	$("#NewCertificate").click( function () { 
		$.post('/post/shop/again', function(json) {
			
				$('.bootbox').PhpappProgress({json:json});

				return true;
			
		  }, 'json');
		  

		 bootbox.dialog({
			 message: '<div class="progress progress-striped active"><div style="width: 1%" aria-valuemax="100" aria-valuemin="0" aria-valuenow="20" role="progressbar" class="progress-bar progress-bar-info"><span>0%</span></div></div>',
			 title: '<i class="icon fa fa-retweet"></i> 提交中',
			 closeButton: false
		 }).PhpappProgress({time:2000});
	 
		  return false; 
	});	  
})
</script>
{template Public:Page:footer}